package com.wen.springcloud.entity.converter.mapper;

import com.wen.springcloud.entity.dto.UserDTO;
import com.wen.springcloud.entity.po.UserPO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

/**
 * @author Wen
 * @date 2023/3/28 09:58
 */
@Mapper(componentModel = "spring")
public interface UserConverter {

    UserConverter INSTANCE = Mappers.getMapper(UserConverter.class);

    @Mapping(target = "pname", ignore = true)
    UserDTO poToDto(UserPO po);

}
